
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
<script>
class Person {
    constructor() {
        this.name = null;
    }
    getName () {
        console.log(this.name);
    }
}

const xz = new Person();
xz.name = '项总'
xz.getName() // this?
const ysg = new Person();
ysg.name = '袁总';
ysg.getName()
// 
// const getName = xz.getName.bind(ysg);
// getName();
xz.getName.call(ysg)
</script>
</body>
</html>